<?php

/**
 * @author mrHie darkbuivn@gmai.com
 * @copyright 2014
 */
require_once("config.php");
require_once("lib/dbcon.php");
try
{
    $test = new ActiveRecord($username,$password,$database,$server);
    $test->connect();
    $test->table = "users";
    $rows = $test->select(); 
    foreach($rows as $row)
    {
        echo $row['uid']." ".$row['pwd']." ".$row['email']."<br/>"; 
    }
  //  $data = array('uid'=>"member01",'pwd'=>"345",'email'=>"member01@localhost.com");
  //  $test->insert($data);
  /*
    // update database
     $data = array('pwd'=>"Maria");
     $test->condition = "uid = 'admin'";
     $test->update($data);
     echo $test->AffectedRows;
  */
}
catch(DBConnException $e)
{
    echo $e->getMessage();
}

?>